package com.niguang.work.api.controller;


import com.niguang.common.pojo.Result;
import com.niguang.work.api.service.ReformUserService;
import com.niguang.work.api.service.WechatUserService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import javax.validation.constraints.NotNull;


/**
 * 小程序整改单首页进入
 */
@RestController
@RequestMapping("/api/rectification/")
public class WeChatRectificationController {

    @Resource
    private WechatUserService wechatUserService;

    @Resource
    private ReformUserService reformUserService;

    /**
     * 获取用户项目
     *
     * @return
     */
    @GetMapping("getSiteList")
    public Result getSiteList(String keyText) {
        return reformUserService.getSiteList(keyText);
    }


    /**
     * 检测用户是否绑定微信
     *
     * @return
     */
    @GetMapping("checkUser")
    public Result checkUser() {
        return reformUserService.checkUser();
    }


}
